/******************************************************************************

                            Online Java Compiler.
                Code, Compile, Run and Debug java program online.
Write your code in this editor and press "Run" button to execute it.

*******************************************************************************/

import java.util.*;
public class Main
{
  public static void main (String[]args)
  {
    System.out.println ("(x = (-b +/- sqrt(b^2 - 4 a c))/(2 a))");

    Scanner myObj = new Scanner (System.in);	// Create a Scanner object
      System.out.println ("Enter a");

    double a = myObj.nextDouble ();	// Read user input

    while (a == 0)
      {
	System.out.println ("a cannot be 0!");
	a = myObj.nextDouble ();	// Read user input
      }

    System.out.println ("a = " + a);	// Output user input

    System.out.println ("Enter b");

    double b = myObj.nextDouble ();	// Read user input
    System.out.println ("b = " + b);	// Output user input

    System.out.println ("Enter c");

    double c = myObj.nextDouble ();	// Read user input
    System.out.println ("c = " + c);	// Output user input

    double x1 = (-b + Math.sqrt (b * b - 4 * a * c)) / (2 * a);

    System.out.println ("Possitive squate is: " + x1);	// Output user input

    double x2 = (-b - Math.sqrt (b * b - 4 * a * c)) / (2 * a);

    System.out.println ("Negative squate is: " + x2);	// Output user input
  }
}